<#include "include/_meta.html">
<html>
<head>
	<title>管理员列表</title>

</head>
<body>
<nav class="breadcrumb"><i class="Hui-iconfont">&#xe67f;</i> 首页 <span class="c-gray en">&gt;</span> 车辆管理<span class="c-gray en">&gt;</span> 车辆保险记录列表 <a class="btn btn-success radius r" style="line-height:1.6em;margin-top:3px" href="javascript:location.replace(location.href);" title="刷新" ><i class="Hui-iconfont">&#xe68f;</i></a></nav>
<div class="page-container">
	<div id="app" class="app">
		<form id="addf" onsubmit="return false">
			<table class="table">
				<tr>
					<td>记录编号：</td><td><input type="text" required="required"  id="recordid" name="recordid">
					</td>
				</tr>
				<tr>
					<td>车辆编号:</td><td><input type="text" required="required" id="carid" name="carid">
					</td>
				</tr>
				<tr>
					<td>保险公司：</td><td><input type="text" required="required" id="company" name="company">
					</td>
				</tr>
				<tr>
					<td>出现电话：</td><td><input type="text" id="companyphone" name="companyphone">
					</td>
				</tr>
				<tr>
					<td>保单编号:</td><td><input type="text" id="code" name="code">
					</td>
				</tr>
				<tr>
					<td>保单内容:</td><td><input type="text" id="content" name="content">
					</td>
				</tr>
				<tr>
					<td>保单费用:</td><td><input type="text" id="money" name="money">
					</td>
				</tr>
				<tr>
					<td>生效日期:</td><td><input type="date" required="required" id="validdate" name="validdate">
					</td>
				</tr>
				<tr>
					<td>失效日期:</td><td><input type="date" required="required" id="invaliddate" name="invaliddate">
					</td>
				</tr>
				<tr>
					<td>经办人员:</td><td><input type="text" id="contactman" name="contactman">
					</td>
				</tr>
				<tr>
					<td>经办手机:</td><td><input type="text" id="contactmobile" name="contactmobile">
					</td>
				</tr>
				<tr>
					<td>备注信息:</td><td><input type="text" id="remark" name="remark">
					</td>
				</tr>
				<tr>
					<td>系统时间:</td><td><input type="date" required="required" id="addtime" name="addtime"></td>
				</tr>
				<tr>
					<td><input id="buss" type="submit" value="提交"> </td><td><input id="cancelBtn" type="button" value="取消"> </td>
				</tr>
			</table>
		</form>
	</div>
</div>
<#include "include/_footer.html">
<script>
	$("#cancelBtn").click(function () {
		var index=parent.layer.getFrameIndex(window.name);
		parent.getCarInsuPagelist();
		parent.layer.close(index);
	});
	$('#addf').validate({
		keyup: false,
		onblur: true,
		rules: {
			recordid:{
				required: true
			},
			carid:{
				required: true
			},
			company:{
				required: true
			},
			companyphone:{
				required: true
			},
			code:{
				required: true
			},
			content:{
				required: true
			},
			money:{
				required: true,
				number: true
			},
			validdate:{
				required: true
			},
			contactman:{
				required: true
			},
			invaliddate:{
				required: true
			},
			contactmobile:{
				required: true
			},
			remark:{
				required: true
			},
			addtime:{
				required: true
			}
		},
		submitHandler: function () {
			$.ajax({
				url:'/insures/addsss',
				type:'POST',
				dataType:'json',
				data:$('#addf').serialize(),
				success:function (data) {
					if (data!=0){
						var index = parent.layer.getFrameIndex(window.name);
						parent.getCarInsuPagelist();
						parent.layer.close(index);
					}
					else {
						layer.alert('添加失败');
					}
				}
			});
		}
	});

</script>
</body>
</html>